﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="080829kecheng_search_free.aspx.cs" Inherits="kecheng_kecheng_search_free" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>无标题页</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
       <table width="872" border="0" cellpadding="0" cellspacing="0" class="table_border">
        <tr valign="top">
            <td colspan="2" style="height: 7px; width: 787px;">
                <table width="100%">
                    <tr>
                        <td style="width: 147px">
                            <asp:Label ID="Label2" runat="server" Font-Bold="True" Text="选择查询条件" Width="102px"></asp:Label></td>
                        <td style="width: 159px">
                        </td>
                        <td style="width: 150px; text-align: center">
                            </td>
                        <td style="width: 126px; text-align: right;">
                            <asp:TextBox ID="TextBox2" runat="server" Width="100px"></asp:TextBox></td>
                        <td style="width: 100px">
                            <asp:Button ID="Button5" runat="server" OnClick="Button5_Click" Text="按名称查询" Width="72px" /></td>
                        <td style="width: 88px">
                            <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="~/index.aspx">返回首页</asp:HyperLink></td>
                    </tr>
                    <tr>
                        <td style="width: 147px">
                            &nbsp;<asp:Label ID="Label1" runat="server" Font-Size="Smaller" Text="作用分类"></asp:Label>
                            <asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="True" DataSourceID="SqlDataSource3"
                                DataTextField="value" DataValueField="value" Width="85px">
                            </asp:DropDownList></td>
                        <td style="width: 159px">
                            <asp:Label ID="Label3" runat="server" Font-Size="Smaller" Text="学习对象" Width="53px"></asp:Label>
                            <asp:DropDownList ID="DropDownList2" runat="server" AutoPostBack="True" DataSourceID="SqlDataSource4"
                                DataTextField="value" DataValueField="value" Width="85px">
                            </asp:DropDownList></td>
                        <td style="width: 150px">
                            &nbsp;<asp:Label ID="Label5" runat="server" Font-Size="Smaller" Text="课程分类"></asp:Label>
                            <asp:DropDownList ID="DropDownList3" runat="server" AutoPostBack="True" DataSourceID="SqlDataSource5"
                                DataTextField="value" DataValueField="value" Width="85px">
                            </asp:DropDownList></td>
                        <td style="width: 126px; text-align: right;">
                            <asp:Label ID="Label4" runat="server" Font-Size="Smaller" Text="类型"></asp:Label>
                            <asp:DropDownList ID="DropDownList4" runat="server" AutoPostBack="True" DataSourceID="SqlDataSource6"
                                DataTextField="value" DataValueField="value" Width="85px">
                            </asp:DropDownList></td>
                        <td style="width: 100px">
                            <asp:Button ID="Button2" runat="server" OnClick="Button2_Click" Text="开始查询" EnableTheming="False" /></td>
                        <td style="width: 88px">
                            <asp:Button ID="Button3" runat="server" OnClick="Button3_Click" Text="清空选择" EnableTheming="False" /></td>
                    </tr>
                </table>
                &nbsp;&nbsp;
            </td>
        </tr>
        <tr valign="top">
            <td colspan="2" height="7" style="text-align: center; width: 787px;" class="font3">
                <strong>查询结果</strong></td>
        </tr>
        <tr valign="top">
            <td colspan="2" style="width: 787px">
                <table width="770" border="1" align="center" cellpadding="4" cellspacing="0" >
                    <tr>
                        <td height="90" colspan="2" align="left" valign="top">
                            <table border="0" width="100%">
                                <tr>
                                    <td style="width: 38%; height: 356px; vertical-align: top;" class="font3">
                                        <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" DataSourceID="SqlDataSource1"
                                            AllowPaging="True" AllowSorting="True" OnRowDataBound="GridView1_RowDataBound"
                                            OnSelectedIndexChanging="GridView1_SelectedIndexChanging" DataKeyNames="id" CellPadding="4"
                                            Font-Size="10pt" ForeColor="Black" GridLines="Vertical" OnRowCommand="GridView1_RowCommand"
                                            Width="497px" PageSize="13" BackColor="White" BorderColor="#DEDFDE" BorderStyle="None" BorderWidth="0px">
                                            <Columns>
                                                <asp:BoundField HeaderText="编号" />
                                                <asp:TemplateField HeaderText="选择" Visible="False">
                                                    <ItemTemplate>
                                                        <asp:CheckBox ID="CheckBox1" runat="server" />
                                                    </ItemTemplate>
                                                </asp:TemplateField>
                                                <asp:CommandField HeaderText="查看详细" SelectText="查看详细" ShowSelectButton="True" />
                                                <asp:BoundField DataField="id" HeaderText="代码" SortExpression="id" />
                                                <asp:TemplateField HeaderText="课程">
                                                    <ItemTemplate>
                                                        <asp:LinkButton ID="Button4" CommandArgument='<%#Eval("id") %>' runat="server" OnClick="Button4_Click"
                                                            Text='<%# Eval("name")  %>' />
                                                    </ItemTemplate>
                                                </asp:TemplateField>
                                                <asp:BoundField DataField="kechenglx" HeaderText="课程类型" SortExpression="name" Visible="False" />
                                                <asp:BoundField DataField="jigou" HeaderText="机构" SortExpression="jigou" Visible="False" />
                                                <asp:BoundField DataField="laoshi" HeaderText="任课老师" SortExpression="laoshi" />
                                                <asp:BoundField DataField="xuefei" HeaderText="收费" SortExpression="xuefei" />
                                            </Columns>
                                            <RowStyle BackColor="#F7F7DE" />
                                            <SelectedRowStyle BackColor="#CE5D5A" Font-Bold="True" ForeColor="White" />
                                            <PagerStyle BackColor="#F7F7DE" ForeColor="Black" HorizontalAlign="Right" />
                                            <HeaderStyle BackColor="#D9EDB2" Font-Bold="True" ForeColor="Black" Font-Underline="False"/>
                                            <FooterStyle BackColor="#CCCC99" />
                                            <AlternatingRowStyle BackColor="White" />
                                        </asp:GridView>
                                        &nbsp;&nbsp;
                                    </td>
                                    <td style="height: 356px; width: 32%; vertical-align: top;">
                                        <asp:DetailsView ID="DetailsView1" runat="server" Height="360px" Width="347px" AutoGenerateRows="False"
                                            DataSourceID="SqlDataSource2" CellPadding="4" Font-Size="10pt" ForeColor="#333333"
                                            GridLines="None">
                                            <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
                                            <CommandRowStyle BackColor="#E2DED6" Font-Bold="True" Wrap="True" />
                                            <EditRowStyle BackColor="#999999" />
                                            <RowStyle BackColor="#F7F7DE" />
                                            <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
                                            <FieldHeaderStyle BackColor="#E9ECF1" Font-Bold="True" Width="50px" />
                                            <HeaderStyle BackColor="#D9EDB2" Font-Bold="True" ForeColor="Black" Font-Underline="False"/>
                                            <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
                                            <Fields>
                                                <asp:BoundField DataField="name" HeaderText="名称" SortExpression="name" />
                                                <asp:BoundField DataField="laoshi" HeaderText="老师" SortExpression="laoshi" />
                                                <asp:BoundField DataField="jigou" HeaderText="机构" SortExpression="jigou" />
                                                <asp:BoundField DataField="kechenglx" HeaderText="类型" SortExpression="kechenglx" />
                                                <asp:BoundField DataField="fabuzt" HeaderText="发布" SortExpression="fabuzt" />
                                                <asp:BoundField DataField="xuefei" HeaderText="学费" SortExpression="xuefei" />
                                                <asp:BoundField DataField="jifen" HeaderText="积分" SortExpression="jifen" />
                                                <asp:TemplateField HeaderText="简介">
                                                    <ItemTemplate>
                                                        <asp:TextBox ID="TextBox1" runat="server" Font-Size="10pt" Height="265px" Text='<%# Eval("jianjie") %>'
                                                            TextMode="MultiLine" Width="270px"></asp:TextBox>
                                                    </ItemTemplate>
                                                </asp:TemplateField>
                                            </Fields>
                                        </asp:DetailsView>
                                    </td>
                                </tr>
                                <tr>
                                    <td style="width: 38%; height: 15px">
                                        </td>
                                    <td style="height: 15px; width: 32%;">
                                    </td>
                                </tr>
                                <tr>
                                    <td style="width: 38%; height: 45px;">
                                        <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:gConnectionString %>"
                                            SelectCommand="SELECT * FROM [kecheng] WHERE ([confirm] = @confirm)">
                                            <SelectParameters>
                                                <asp:Parameter DefaultValue="终审通过" Name="confirm" Type="String" />
                                            </SelectParameters>
                                        </asp:SqlDataSource>
                                    </td>
                                    <td style="height: 45px; width: 32%;">
                                        <asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:gConnectionString %>"
                                            SelectCommand="SELECT * FROM [kecheng] where id=0"></asp:SqlDataSource>
                                    </td>
                                </tr>
                            </table>
                            &nbsp;&nbsp;<br />
                            &nbsp;<br />
                            &nbsp; &nbsp; &nbsp;&nbsp;
                        </td>
                    </tr>
                    <tr>
                        <td height="30" colspan="2">
                            <asp:SqlDataSource ID="SqlDataSource3" runat="server" ConnectionString="<%$ ConnectionStrings:gConnectionString %>"
                                SelectCommand="SELECT * FROM [nzd] WHERE ([type] = @type)">
                                <SelectParameters>
                                    <asp:Parameter DefaultValue="专业分类1" Name="type" Type="String" />
                                </SelectParameters>
                            </asp:SqlDataSource>
                            <asp:SqlDataSource ID="SqlDataSource4" runat="server" ConnectionString="<%$ ConnectionStrings:gConnectionString %>"
                                SelectCommand="SELECT * FROM [nzd] WHERE ([type] = @type)">
                                <SelectParameters>
                                    <asp:Parameter DefaultValue="专业分类2" Name="type" Type="String" />
                                </SelectParameters>
                            </asp:SqlDataSource>
                            <asp:SqlDataSource ID="SqlDataSource5" runat="server" ConnectionString="<%$ ConnectionStrings:gConnectionString %>"
                                SelectCommand="SELECT * FROM [nzd] WHERE ([type] = @type)">
                                <SelectParameters>
                                    <asp:Parameter DefaultValue="专业分类3" Name="type" Type="String" />
                                </SelectParameters>
                            </asp:SqlDataSource>
                            <asp:SqlDataSource ID="SqlDataSource6" runat="server" ConnectionString="<%$ ConnectionStrings:gConnectionString %>"
                                SelectCommand="SELECT * FROM [nzd] WHERE ([type] = @type)">
                                <SelectParameters>
                                    <asp:Parameter DefaultValue="课程类型" Name="type" Type="String" />
                                </SelectParameters>
                            </asp:SqlDataSource>
                            &nbsp;
                        </td>
                    </tr>
                </table>
            </td>
        </tr>
        <tr>
            <td height="1" colspan="2" bgcolor="#128bbe" style="width: 787px">
            </td>
        </tr>
    </table>
    </div>
    </form>
</body>
</html>
